package com.xyd.dao;

import com.xyd.bean.User;
import org.apache.ibatis.annotations.Param;

import java.util.List;

public interface UserMapper {
    //异步注册提示
    User regUser(@Param("uname") String uname);
    //注册添加用户
    int insertUser(@Param("uname") String uname,@Param("upass") String upass);
    //用户登录
    User loginUser(@Param("uname") String uname,@Param("upass") String upass);
    //获取所有user
    List<User> getAllUser();
    //根据uid找到对应的user
    User getByUid(Integer uid);
    //根据uid更新user数据
    int updateByUid(User user);
    //根据uid删除user
    int delByUid(Integer uid);
    //管理员添加用户
    int insertAll(User user);
}